<?php
namespace app\rpc\controllers;

use app\rpc\lib\RpcLib;
use config\config;
use lib\redis\RedisTool;
use lib\rule\ParentInit;

class MyController extends ParentInit{

    public function actionIndex(){
        $rpc = config::get('rpc');
//        RedisTool::_init()->setKey('RPC_STATE')->setString(['state'=>1,'this_time'=>date('m-d H:i')])->getReturn();
        return new RpcLib($rpc['ip'],$rpc['port']);
    }
}